FROM openjdk:11.0.14.1-jre
ARG appJar
ARG workspace=/workspace
ENV TZ=Asia/Shanghai
COPY build/libs/$appJar $workspace/$appJar
COPY build/bin/server-img-user.sh $workspace/server-img-user.sh
COPY build/bin/server-img.sh $workspace/server-img.sh
WORKDIR $workspace
RUN ln -sf /usr/share/zoneinfo/$TZ /etc/localtime
RUN echo $TZ > /etc/timezone
RUN bash -c "touch $appJar"
ENTRYPOINT ["bash","server-img-user.sh"]